package com.android.camera.one.v2.camera2proxy;

import javax.annotation.Nonnull;
import javax.annotation.Nullable;

import com.android.camera.async.SafeCloseable;

import android.media.ImageReader;
import android.os.Handler;

public interface ImageWriterProxy extends SafeCloseable {
	/**
     * See {@link ImageWriter.OnImageReleasedListener}
     */
    public interface OnImageReleasedListener {
        /**
         * See {@link ImageReader.OnImageAvailableListener#onImageAvailable}
         */
        public void onImageReleased(ImageWriterProxy proxy);
    }
    
    public int getMaxImages();
    
    public int getFormat();
    
    public ImageProxy dequeueInputImage();
    
    public void queueInputImage(ImageProxy image);
    
    public void setOnImageReleasedListener(
    		@Nonnull OnImageReleasedListener listener, 
    		@Nullable Handler handler);
    
    public void close();
    
    public boolean isClosed();
}
